package templates

var RouterTpl = `package router

import (
	"{{StructAppPath}}/controller"
	"github.com/gin-gonic/gin"
)

func {{StructReturnName}}Router(router *gin.Engine) {
	{{StructReturnName}} := controllers.{{StructName}}Controller{}
	{{StructReturnName}}R := router.Group("{{StructRoute}}")
	{
		{{StructReturnName}}R.GET("/", {{StructReturnName}}.Find)
		{{StructReturnName}}R.POST("/", {{StructReturnName}}.Create)
		{{StructReturnName}}R.GET("/get-by-id/:id", {{StructReturnName}}.FindById)
		{{StructReturnName}}R.POST("/update-by-id", {{StructReturnName}}.UpdateById)
	}
}`
